<form name="frmListLocation" id="frmListLocation">
<table border="1" cellspacing="1px" cellpadding="10px "align="center" width="100%">
    <tr>
        <th width="15">#</th>
        <th>Location name</th>
    </tr>
    <{foreach name = nameLocation key = keyLocation item = itemLocation from = $arrLocation}>
    <tr>
        <td><{$keyLocation+1}></td>
        <td>
        	<input type="text" size="70" name="location_name_<{$itemLocation.id}>" id="location_name_<{$itemLocation.id}>" value="<{$itemLocation.location_name}>" />
        	<input type="button" value=" Update " onclick="javascript:updateLocation(this, <{$itemLocation.id}>)" name="btnUpdate<{$itemLocation.id}>" id="btnUpdate<{$itemLocation.id}>" />
        </td>
    </tr>
    <{/foreach}>
</table>
</form>
<form name="frmAddLocation" id="frmAddLocation" onsubmit="return checkFrmAddLocation(this)">
<table border="0" cellpadding="2" cellspacing="1">
	<tr>
  	<td>
    	Location name: <input type="text" name="location_name" id="location_name" value="" size="50" />
      <input type="submit" name="btnAddLocation" id="btnAddLocation" value=" Add " />
    </td>
  </tr>
</table>
</form>